-
-
Notifications
You must be signed in to change notification settings - Fork 807
📝 Update docs to use Typer() more prominently
#1418
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
svlandeg
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok, this should be now in a good state.
Searching through the code base, the only places that still refer to typer.run() are
- the "first steps" part of the tutorial
docs_src/arguments/optional/tutorial000.pywhich was created in this PR specifically to gradually build up the complexity in the "Arguments" docs sectiondocs_src/testing/app03which specifically talks about testing code that don't useTyper()
Everything else is now converted to Typer() and all highlighting in the documentation has been updated, including a few fixes of things that weren't exactly right on master (made separate comments about these).
tiangolo
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is looking great! 🚀 🎉
Thanks a lot for going through it all! 🙌
I just reviewed everything, it all looks good. I didn't review the highlighted lines, but I know you did.
I was thinking about the new page name, what do you think?
tiangolo
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Amazing, thank you! 🙌
In an attempt to be minimal/clear, the docs have mostly been using
typer.run. However for proper applications, we recommend to useTyper()directly, which unlocks much more options. As such, we're updating the docs here. This has the added advantage that it's easier to experiment with given tutorial examples without first having to adjust them to useTyper().I know reviewing this is horrible. I've taken the time to go through every edit carefully (0% vibe coding ;-)). Mostly, this meant updating the tutorial examples and then updating the highlighted lines in the documentation markdown files. There were some special cases, that I'll highlight as review comments.